import request from '@/utils/request'

// 获取RTU配置
export function getRtuConfig(params) {
  return request({
    url: '/api/config/get-rtu-config',
    method: 'get',
    params
  })
}

// 获取指定DTU设备配置
export function getDtuConfig(uuid) {
  return request({
    url: '/api/config/get-dtu-config',
    method: 'get',
    params: {dtuUuid: uuid}
  })
}

// 更新指定DTU配置
export function setDTUConfigToDevice(data) {
  return request({
    url: '/api/config/set-dtu-config-to-device',
    method: 'post',
    data
  })
}

// 更新指定RTU配置
export function setRTUConfigToDevice(data) {
  return request({
    url: '/api/config/set-rtu-config-to-device',
    method: 'post',
    data
  })
}